package top.huhuiyu.springboot3.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;
import java.util.Date;

@Data
// 实体类对应的表名称
@TableName("tb_class")
public class TbClass implements Serializable {
    @Serial
    private static final long serialVersionUID = 1L;

    // 自增主键
    @TableId(type = IdType.AUTO)
    private Integer id;
    private String cname;
    private String description;
    // 默认字段，不允许插入和修改
    @TableField(insertStrategy = FieldStrategy.NEVER, updateStrategy = FieldStrategy.NEVER)
    private Date createAt;

}
